using Proto;

namespace sgf.server.hotfix
{
    public static class NetActorSystem
    {
        public class NetActorStartSystem : OnStartSystem<NetActor>
        {
            public override async Task OnStart(NetActor busActor, IContext context)
            {
                await busActor.AddMgrSync<NetMgr>();
                // _netServer = new KestrelNetServer();
                // await _netServer.Start(new TcpNetStartConfig(Config.GetInt("port")));
            }
        }

        //OnMsg
        public class NetActorMsgSystem : OnMsgSystem<NetActor>
        {
            public override async Task OnMsg(NetActor busActor, IContext context)
            {
                await busActor.OnMsg(context);
            }
        }
    }
}